<template>
  <BaseContainer>
    <el-tabs v-model="activeName" class="demo-tabs"  tabPosition="left">
      <el-tab-pane v-for="(item, index) in tabs" :key="index" :label="item.label" :name="item.name">
      </el-tab-pane>
      <component  :is="whichCommand[activeName]" :module="0" :dataType="activeName"></component>
    </el-tabs>
  </BaseContainer>
</template>

<script setup lang="ts">
import PensionInformation from './PensionInformation/index.vue'
import PolicyDocuments from './PolicyDocuments/index.vue'

const route = useRoute()
const baseActive = route.query.activeName||'1' as any
let activeName = ref(baseActive)

const whichCommand = {
  1:PensionInformation,
  2:PolicyDocuments
}
const tabs = [
  { label: '养老资讯', name: '1', component: 'PensionInformation' },
  { label: '政策文件', name: '2',component:'PolicyDocuments' },
]

</script>

<style scoped></style>
